<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet"
	href="/resources/styles/bootstrap/3.3.5/css/bootstrap.min.css" />
<link rel="stylesheet"
	href="/resources/styles/bootstrap/3.3.5/css/bootstrap-theme.min.css" />
<link rel="stylesheet" href="/resources/styles/pivotal.css" />
<title>security: Edit Account Details</title>
</head>

<body>

	<div class="container">
		<div class="row">
			<nav class="navbar navbar-inverse">
			<div class="container-fluid">
				<div class="navbar-header">
					<a title="Spring IO" href="http://www.spring.io"> <img
						src="/resources/images/spring-trans-dark.png" height="50" />
					</a>
				</div>
				<div>
					<ul class="nav navbar-nav navbar-right">
						<li><a href="http://www.pivotal.io"> <img alt="Pivotal"
								title="Pivotal" height="20"
								src="/resources/images/pivotal-logo-600.png" />
						</a></li>
					</ul>
				</div>
			</div>
			</nav>
		</div>

		<div class="row">

			<h1>Edit Account Details</h1>

 			<form action="editAccount" method="post" class="form-horizontal">
				<fieldset>
					<div class="form-group">
						<label class="control-label col-sm-2" for="number"> Number
						</label>
						<div class="col-sm-4">
							<input name="number" value="{{account.number}}" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label class="control-label col-sm-2" for="name"> Name </label>
						<div class="col-sm-4">
							<input name="name" value="{{account.name}}" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<div class="col-sm-offset-2 col-sm-10">
							<button id="saveButton" type="submit" class="btn button-default">
								Update Account</button>
						</div>
					</div>
					<!--  This will be automatically made available by Spring Security -->
					{{#_csrf}}
					<input type="hidden" name="_csrf" value="{{_csrf.token}}" />
					{{/_csrf}}
				</fieldset>
			</form>
		</div>

		<div class="row">
			<div style="margin-left: 10pt">
        			<a href="/accounts/accountDetails?entityId={{account.entityId}}">Back</a>
			</div>

			{{#principal}}
			<div>
				<form action="/logout" method="post" class="form-horizontal">
					<fieldset>
						<input type="submit" value="Logout" class="btn btn-link" />
	
						<!--  This will be automatically made available by Spring Security -->
						{{#_csrf}}
						<input type="hidden" name="_csrf" value="{{_csrf.token}}" />
						{{/_csrf}}
	
						({{principal.username}})
					</fieldset>
				</form>
			</div>
			{{/principal}}

		</div>
	</div>
</body>

</html>